@keyframes fx-animation-notify-right-enter {
  from {
    transform: translateX(100%);
  }
  to {
    transform: translateX(0);
  }
}

@keyframes fx-animation-notify-right-leave {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(100%);
  }
}

@keyframes fx-animation-notify-left-enter {
  from {
    transform: translateX(-100%);
  }
  to {
    transform: translateX(0);
  }
}

@keyframes fx-animation-notify-left-leave {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-100%);
  }
}

.fx-notify {
  position: fixed;
  z-index: 1002;
  transform: translateX(-50%);
  border-radius: $border-radius-default;
  transition: all 0.3s;
  padding: 20px 30px;
  box-shadow: $border-shadow;
  background-color: $notify-background;
  display: flex;

  &.top-left, &.bottom-left {
    animation: fx-animation-notify-left-enter 0.3s forwards;

    &.close {
      animation: fx-animation-notify-left-leave 0.3s forwards;
    }
  }

  &.top-right, &.bottom-right {
    animation: fx-animation-notify-right-enter 0.3s forwards;

    &.close {
      animation: fx-animation-notify-right-leave 0.3s forwards;
    }
  }

  &.primary {
    > .type-icon {
      color: $color-primary;
    }
  }

  &.success {
    > .type-icon {
      color: $color-success;
    }
  }

  &.warning {
    > .type-icon {
      color: $color-warning;
    }
  }

  &.error {
    > .type-icon {
      color: $color-error;
    }
  }

  > .type-icon {
    width: 24px;
  }

  > .notify-content {
    width: 240px;

    > .title {
      height: 24px;
      line-height: 24px;
      font-size: 16px;
      font-weight: bolder;
      color: $font-color-important;
    }
  }

  > .close {
    cursor: pointer;
    position: absolute;
    right: 15px;
    top: 10px;
  }
}
